import { color } from "echarts/core";
import { EChartsOption } from "echarts/types/dist/shared";

/**
 * 市域地图
 */
export let mapOption: EChartsOption = {
    visualMap: {},
    geo: {
        map: 'beijing'
    },
    series: [
        {
            name: '北京市分布',
            type: 'map',
            coordinateSystem: 'geo',
            map: 'beijing',
            label: {
                show: true
            },
            data: []
        },
    ]
};

/**
 * 区域地图，必须配置，每张地图都需要一个配置，不能共用
 */
export let areaMapOption: EChartsOption = {
    visualMap: {
        show: false
    },
    geo: {
        map: 'dongcheng'
    },
    series: [
        {
            name: 'distribution',
            type: 'scatter',
            coordinateSystem: 'geo',
            data: []
        },
    ]
};

export let graphOption: EChartsOption = {
    animationDurationUpdate: 1500,
    animationEasingUpdate: 'quinticInOut',
    series: [
        {
            type: 'graph',
            layout: 'none',
            symbolSize: 50,
            roam: true,
            label: {
                show: true
            },
            edgeSymbol: ['circle', 'arrow'],
            edgeSymbolSize: [4, 10],
            edgeLabel: {
                fontSize: 20
            },
            data: [],
            links: [],
            lineStyle: {
                opacity: 0.9,
                width: 2,
                curveness: 0
            }
        }
    ]
}